package com.usian.wemedia.controller;/*
 *文件名：WmNewsController
 *创建者：宋璟
 *创建时间:2023/2/13 18:41
 *描述: TODO
 */

import com.usian.api.wemedia.WmNewsControllerApi;
import com.usian.model.common.dtos.ResponseResult;
import com.usian.model.media.dtos.WmNewsDto;
import com.usian.model.media.dtos.WmNewsPageReqDto;
import com.usian.wemedia.service.WmNewsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/api/v1/news")
public class WmNewsController implements WmNewsControllerApi {

    @Autowired
    WmNewsService wmNewsService;

    @PostMapping("/list")
    @Override
    public ResponseResult findAll(WmNewsPageReqDto wmNewsPageReqDto) {
        return wmNewsService.findAll(wmNewsPageReqDto);
    }


    @Override
    public ResponseResult submitNews(WmNewsDto wmNews) {
        return null;
    }
}
